package cn.tedu.spring.config;

import cn.tedu.spring.auto.UserAuto;
import cn.tedu.spring.file.Database;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class TestAppConfig {
    public static void main(String[] args) {
        AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(AppConfig.class);
        Database database=context.getBean(Database.class);
        System.out.println(database);
        UserAuto userAuto=context.getBean(UserAuto.class);
        System.out.println(userAuto);
        }
    }

